package domini;


/**
 *  <p style="margin-top: 0">
 *        Modela les tarifes a aplicar a les ocupacions.
 *      </p>
 */
// <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
// #[regen=yes,id=DCE.BC7C2BB6-5318-6125-9FF9-85CC3194CC0C]
// </editor-fold> 
public class Tarifa {

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.43E87CCB-BC04-CC06-A97B-9CEB0D82A5CC]
    // </editor-fold> 
    private int eoid;

    /**
     *  <p style="margin-top: 0">
     *        Instant inicial de la tarifa en format dd/mm/aaaa-hh:mm
     *      </p>
     */
    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.C36E372F-67C6-308D-9F2D-8EE087CC980E]
    // </editor-fold> 
    private String dtInici;

    /**
     *  <p style="margin-top: 0">
     *        Instant final de la tarifa en format dd/mm/aaaa-hh:mm
     *      </p>
     */
    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.F530D2EE-EBBD-6147-3807-84CC15145E28]
    // </editor-fold> 
    private String dtFi;

    /**
     *  <p style="margin-top: 0">
     *        Preu en &#8364; per minut de la tarifa.
     *      </p>
     */
    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.12588A6E-E8B9-6A81-940A-CA2D8626C06E]
    // </editor-fold> 
    private double preu;

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.60A4709B-E9D0-D5D5-0F6D-96627F840448]
    // </editor-fold> 
    public Tarifa (int eoid) {
        this.eoid = eoid;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.EB466955-8B4E-64FD-F890-D57CF2D6FD22]
    // </editor-fold> 
    public Tarifa (int eoid, String dtInici, String dtFi, double preu) {
        this.eoid = eoid;
        this.dtInici = dtInici;
        this.dtFi = dtFi;
        this.preu = preu;
    }

    @Override

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.5C62C21A-4FEA-57BA-EA4D-35340B7A4C70]
    // </editor-fold> 
    public boolean equals (Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        Tarifa other = (Tarifa) obj;
        if (this.eoid != other.eoid) {
            return false;
        }
        return true;
    }

    @Override

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.DF5C611D-3857-39EF-AE6C-DA88CC7CD27A]
    // </editor-fold> 
    public int hashCode () {
        int hash = 5;
        hash = 67 * hash + this.eoid;
        return hash;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.30B4A47A-4898-BEDF-74F6-0215BAD53BCF]
    // </editor-fold> 
    public String getDtFi () {
        return dtFi;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.F08C2B50-86CF-CEF0-F8F5-30B2EE58C880]
    // </editor-fold> 
    public void setDtFi (String dtFi) {
        this.dtFi = dtFi;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.9F218085-45E4-8A56-CC0A-3FF3D1B757F1]
    // </editor-fold> 
    public String getDtInici () {
        return dtInici;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.94BD4525-F512-9E1B-1E55-22E08FABE90A]
    // </editor-fold> 
    public void setDtInici (String dtInici) {
        this.dtInici = dtInici;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.1D1D4524-DF64-8D98-6416-8C2E50AEDC44]
    // </editor-fold> 
    public int getEoid () {
        return eoid;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.EB335823-6F99-1918-C751-C31B7A2C60D2]
    // </editor-fold> 
    public double getPreu () {
        return preu;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.4D4BFA62-7C61-4C1D-2E97-EF1914546016]
    // </editor-fold> 
    public void setPreu (double preu) {
        this.preu = preu;
    }

    @Override

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.07F56DDB-A7B9-2A63-8D19-6F1617A9B174]
    // </editor-fold> 
    public String toString () {
        String str = "[Eoid: " + eoid + "Data inici: " + dtInici + "Data fi: " + dtFi + "]";
        return str;
    }
}
